///// 全局方法写在此处 /////
///// 用法：this.common.msg('登录成功');

import { Message } from "element-ui";
import {formatDate} from './formatDate.js'; 
export default({
    //提示框
    msg:(msg,type)=>{
        Message({
            message: msg,
            type: type?type:'success'
        });
    },
	//时间戳 => 时间
	timestamp:(time)=>{
		let date = new Date(time*1000);
		return formatDate(date,'yyyy-MM-dd hh:mm:ss');
	},
})
